package client

import (
	log "github.com/sirupsen/logrus"
	"net/rpc"
)

type RpcHttpClient struct {
	address string
	client  *rpc.Client
}

func NewRpcHttpClient() *RpcHttpClient {
	c := &RpcHttpClient{}
	return c
}

func (c *RpcHttpClient) connect() {
	client, err := rpc.DialHTTP("tcp", c.address)
	if err != nil {
		log.Fatal("dialing:", err)
	}
	c.client = client
}
